package edu.hebeu.service.impl;


import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import edu.hebeu.mapper.DepartmentMapper;
import edu.hebeu.entity.Department;
import edu.hebeu.service.DepartmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * (Department)表服务实现类
 *
 * @author makejava
 * @since 2024-12-06 09:50:11
 */
@Service("departmentService")
public class DepartmentServiceImpl extends ServiceImpl<DepartmentMapper, Department> implements DepartmentService {

    @Autowired
    private  DepartmentMapper departmentMapper;
    @Override
    public List<Department> selectLis() {
        EntityWrapper<Department> departmentEntityWrapper = new EntityWrapper<>();
        departmentEntityWrapper.orderBy("id",false);
        //List<Department> departmentList = baseMapper.selectList(departmentEntityWrapper);
        List<Department> departmentList = departmentMapper.selectList(departmentEntityWrapper);
        return departmentList;
    }
}

